:root {
    --clr-neutral-100: hsl(0, 0%, 100%);
    --clr-primary-100: hsl(205, 15%, 58%);
    --clr-primary-400: hsl(215, 25%, 27%);
    --clr-primary-800: hsl(217, 33%, 17%);
    --clr-primary-900: hsl(218, 33%, 9%);
}

html {
    /* 指示呈现颜色方案 */
    color-scheme: dark;
}

body {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    font-size: 1.125rem;
    background-color: var(--clr-primary-800);
}

.tag-list {
    margin: 0;
    padding-inline: 0;
    list-style: none;
}

.tag-list li {
    padding: 1rem;
    background-color: var(--clr-primary-400);
    border-radius: 0.5rem;
    box-shadow: 0 0.5rem 1rem -0.25rem var(--clr-primary-900);
}

.scroller {
    width: 600px;
    /* overflow: hidden; */
}

.scroller__innter {
    display: flex;
    gap: 1rem;
    padding-block: 1rem;
    /* outline: solid red 2px; */
    flex-wrap: wrap;
}

.scroller[data-animate="true"] {
    overflow: hidden;
    mask: linear-gradient(90deg, transparent, white 20%, white 80%, transparent);
}


.scroller[data-duration="fast"] {
    --animation-duration: 10s;
}

.scroller[data-duration="slow"] {
    --animation-duration: 60s;
} 

.scroller[data-direction="left"] {
    --animation-direction: normal;
}

.scroller[data-direction="right"] {
    --animation-direction: reverse;
} 

.scroller[data-animate="true"] .scroller__innter {
    width: max-content;
    flex-wrap: nowrap;
    animation: scroll var(--animation-duration, 10s) var(--animation-direction, normal) linear infinite;
}

@keyframes scroll{
    to {
        transform: translateX(calc(-50% - 0.5rem));
    }
}

.flag {
    background-color: red !important;
}